compareTo

open operator fun compareTo(other: String): Int
open operator override fun compareTo(other: NotBlankString): Int

Compares this value lexicographically with the other value for order. Returns zero if this value equals the other value, a negative number if this value is less than the other value, or a positive number if this value is greater than the other value.